<template>
  <div class="search-wrapper">
    <form action="/">
      <van-search
          background="#FF6933"
          v-model="inputValue"
          shape="round"
          placeholder="请输入搜索关键词"
          search-input-height="200"
          @focus="focusFn"
      >
      </van-search>
    </form>
  </div>
</template>

<script>
export default {
  name: "search",
  data() {
    return {
      inputValue: '',
    };
  },
  methods:{
    focusFn(){
      this.$router.push({
        name: 'search-two'
      })
    }
  },
  watch: {
    inputValue() {
      this.$emit("searchGoodsName", this.inputValue);
    },
  },
}
</script>

<style scoped>
</style>